package com.siashan.toolkit.captcha.easy;

import com.siashan.toolkit.captcha.core.CaptchaData;
import com.siashan.toolkit.captcha.core.CaptchaUtil;
import com.wf.captcha.base.Captcha;

/**
 *
 * @author siashan
 * @since v1.0.1
 **/
public class EasyCaptchaUtil {
    /**
     * 渲染
     */
    public static CaptchaData render(Captcha kaptcha) {
        String text = kaptcha.text();
        String uuid = CaptchaUtil.uuid();
        return CaptchaUtil.captchaData(kaptcha.toBase64(), uuid,text);
    }
}
